Conventionally, the following image retrieval method has been proposed. That is, feature amounts associated with a color, brightness, shape, texture, and the like are extracted by analyzing an image, and are stored as indices in association with the image. Similarities between the feature amounts of an input image (query image) and those of a plurality of stored images are calculated to retrieve an image similar to the query image from the plurality of stored images (an image with a similarity closer to 100% is most similar to the query image).
When a plurality of feature amounts are used in image retrieval, a similarity is calculated by weighting those for respective feature amounts. For example, there are two different feature amounts (feature amounts 1 and 2), and let R1 and R2 be similarities for these feature amounts, and W1 and W2 be weights for these similarities. Then, a final similarity R between images is given by:R=(W1×R1+W2×R2)/(W1+W2)  (1)
If the weights W1=1 and W2=1, the two different feature amounts are treated equally. On the other hand, if the weights W1=3 and W2=1, an image similar to a query image is retrieved while attaching more importance to feature amount 1 than feature amount 2.
In order to implement high-precision image retrieval, it is necessary to appropriately set these weights. Japanese Patent Laid-Open No. 2001-143080 (corresponding U.S. application Ser. No. 09/707,050) discloses a method of designating weights by the user. This method is effective in the following case. For example, when the user inputs a handwritten query image depending on his or her memory, he or she cannot precisely draw ambiguous features. In this manner, the above method is effective when the user can recognize that a specific feature between a query image and desired image is similar compared to other features and which feature is more similar.
Even when an image similar to a desired image is given as a query image, a feature to be weighted may be changed depending on the contents of the image. For example, a printed image of an original image is scanned by a scanner to obtain a scan image, and the scan image is used as a query image. At this time, obviously, the scan image is very similar to the original image.
For example, when images are line images drawn by simple line segments, as shown in FIGS. 11A and 11B, a feature associated with a shape is distinguishable most easily, but color and brightness features are hard to distinguish since there are few such features. FIGS. 11A and 11B show examples of line images.
The user can visually determine a feature to be weighted in case of images formed by simple line segments, as shown in FIGS. 11A and 11B. Even in case of a line image of the same kind, when an image is formed by more complicated figures, and respective figures are hatched and shaded, a brightness feature and the like become also important.
That is, as an image has more complicated contents, it becomes harder to visually determine features and their weights.
In such case, it is difficult for the method of Japanese Patent Laid-Open No. 2001-143080 to designate appropriate weights. Therefore, it is difficult for that method to attain retrieval with higher precision.
When a large number of queries are input to conduct a plurality of retrieval processes at the same time, if the method of Japanese Patent Laid-Open No. 2001-143080 is applied, weights must be designated for each retrieval, thus imposing a heavy load on the user.